extends ./index.jade

block contents
    h2 Overview

    #start.page
        ul.maingrid.small-block-grid-1
            li
                h3 Server
                .panel.inner
                    div
                        span.spaced OS:
                        span(data-bind="text: server().platform")
                    div
                        span.spaced Uptime:
                        span(data-bind="text: server().uptime")
                    div
                        span.spaced CPU Load:
                        span(data-bind="text: server().loadAvg + '% (' + server().cpuCores + ' cores)'")
                    div
                        span.spaced RAM Usage:
                        span(data-bind="text: server().memoryUsage + '% (' + server().memoryTotal + ')'")

            li
                h3 API Modules
                ul.small-block-grid-1
                    // ko foreach: apiModules()
                    li
                        .panel
                            h4(data-bind="text: moduleName")
                            .inner
                                // ko if: data.length > 0
                                strong Data
                                ul
                                    // ko foreach: data
                                    li
                                        span.spaced(data-bind="text: key")
                                        span.timestamp(data-bind="text: lastUpdated")
                                    // /ko
                                // /ko

                                // ko if: jobs.length > 0
                                strong Jobs
                                ul
                                    // ko foreach: jobs
                                    li
                                        span.spaced(data-bind="text: callback")
                                        span.timestamp(data-bind="text: lastRun")
                                    // /ko
                                // /ko
                    // /ko

            li.disabled-modules
                h3 Disabled modules
                .panel.inner
                    div(data-bind="text: disabledManagerModules().join(', ') + ', ' + disabledApiModules().join(', ')")
